home *** CD-ROM | disk | FTP | other *** search
/ Aminet 2 / Aminet AMIGA CDROM (1994)(Walnut Creek)[Feb 1994][W.O. 44790-1].iso / Aminet / dev / asm / TBSource.lha / SimCC / SCheat13a.S < prev    next >
Text File  |  1993-07-02  |  19KB  |  956 lines

  1. ***********************************************
  2. *                                             *
  3. *              (C)opyright 1991               *
  4. *                                             *
  5. *             by  Tomi Blinnikka              *
  6. *                                             *
  7. *             SimCity 1.1  Cheat              *
  8. *                                             *
  9. * Version 0.00a - 0.99a  18/4/1991            *
  10. *                                             *
  11. * BUGS: Didn't work through DOS               *
  12. *                                             *
  13. * Version 1.00  19/4/1991                     *
  14. *                                             *
  15. * BUGS: No WB Stuff + some font stuff         *
  16. *                                             *
  17. * Version 1.01  26-27/4/1991                  *
  18. *                                             *
  19. * BUGS: No font stuff + WB Stuff didn't work  *
  20. *       from directories                      *
  21. *                                             *
  22. * Version 1.02  27-29/4/1991                  *
  23. *                                             *
  24. * BUGS: Doesn't work with CShell          *
  25. *                                             *
  26. * Version 1.03  29/4/1991                  *
  27. *                                             *
  28. * BUGS: Unknown                      *
  29. *                                             *
  30. ***********************************************
  31.  
  32.     INCLUDE    "JMPLibs.i"
  33.     INCLUDE    "exec/types.i"
  34.     INCLUDE    "libraries/dos.i"
  35.     INCLUDE    "libraries/reqbase.i"
  36.     INCLUDE "workbench/startup.i"
  37.     INCLUDE    "intuition.i"
  38.  
  39.     INCLUDE    "dos.xref"
  40.     INCLUDE    "intuition.xref"
  41.     INCLUDE    "exec.xref"
  42.  
  43.     INCLUDE    "FH1:Language/WF/SimCC/SimCC2.0.i"
  44.  
  45.         section    SimCityCheat,CODE
  46.  
  47. Start:        move.l    a0,SCCAddress        ;Get SimCity filename
  48.         move.l    d0,SCCLength        ;Get length
  49.  
  50.         move.l    #0,a1
  51.         lib    Exec,FindTask
  52.         move.l    d0,SCCTask
  53.         move.l    d0,a4
  54.  
  55.         move.l    pr_CLI(a4),d0
  56.         bne    Start1
  57.         jsr    WBStart
  58.  
  59. Start1:        openlib    Dos,ShutDown
  60.  
  61.         lib    Dos,Output
  62.         move.l    d0,_stdout
  63.  
  64. ;        move.l    SCCTask(pc),a4
  65.         move.l    pr_CLI(a4),d0
  66.         beq    WBInput
  67.  
  68. ;CLI Inputs
  69.  
  70.         move.l    SCCAddress,a0
  71.         move.l    SCCLength,d0
  72.         clr.b    -1(a0,d0.l)        ;add null to end of filename
  73.  
  74.         move.l    SCCAddress(pc),a0
  75.         tst.b    (a0)
  76.         bne    GotFileName
  77.         jmp    StartMain
  78.  
  79. WBStart:    lea.l    pr_MsgPort(a4),a0
  80.         lib    Exec,WaitPort
  81.         lea.l    pr_MsgPort(a4),a0
  82.         lib    Exec,GetMsg
  83.         move.l    d0,WBMsg
  84. WBStart1:    rts
  85.  
  86. GotFileName:
  87.         move.w    #1,Mode
  88.         move.l    SCCAddress(pc),a0
  89.         lea.l    FRPathName(pc),a1
  90.         cmp.b    #"?",(a0)
  91.         beq    CommandLineHelp
  92. CopyFName:    move.b    (a0)+,(a1)+
  93.         cmp.b    #$00,(a0)
  94.         bne    CopyFName
  95.         clr.b    (a1)
  96.  
  97.         move.l    SCCAddress(pc),a0
  98.         lea.l    FRFile(pc),a1
  99. CopyFName1:    move.b    (a0)+,(a1)+
  100.         cmp.b    #$20,(a0)
  101.         beq    CopyFName2
  102.         cmp.b    #160,(a0)
  103.         beq    CopyFName2
  104.         cmp.b    #$00,(a0)
  105.         bne    CopyFName1
  106. CopyFName2:    clr.b    (a1)
  107.  
  108.         lea.l    FRFile(pc),a0
  109.         move.l    a0,d1
  110.         move.l    #MODE_OLDFILE,d2
  111.         lib    Dos,Open
  112.         move.l    d0,SCCFile
  113.         bne    DOSCheat
  114.         jsr    SCCNotOpen
  115.         jmp    ShutDown
  116. ;WB Inputs
  117.  
  118. WBInput:
  119.  
  120. ;Open NIL:
  121.  
  122.         lea.l    NILName(pc),a0
  123.         move.l    a0,d1
  124.         move.l    #MODE_NEWFILE,d2
  125.         lib    Dos,Open
  126.         move.l    d0,NILFile
  127.         beq    ShutDown
  128.         move.l    NILFile(pc),_stdout
  129.     
  130.         move.l    #$00,d1
  131.         lib    Dos,CurrentDir
  132.         move.l    d0,OldLock
  133.         move.l    WBMsg(pc),a2
  134.         move.l    sm_NumArgs(a2),ArgsLeft
  135.         move.l    sm_ArgList(a2),ArgList
  136.  
  137. WBInputIn:    sub.l    #1,ArgsLeft
  138.         add.l    #8,ArgList
  139.         cmp.l    #$00,ArgsLeft
  140.         beq    WBInputOut
  141.  
  142. WBInput1:    move.l    ArgList(pc),a0
  143.         move.l    wa_Name(a0),d1
  144.         move.l    d1,a1
  145.         tst.b    (a1)
  146.         bne    WBInput2
  147. WBInput1.1:    move.l    ArgList(pc),a0
  148.         move.l    wa_Lock(a0),d1
  149.         beq    WBInputIn
  150.         lib    Dos,CurrentDir
  151.         move.l    #$00,FRDir
  152.         jmp    WBInputIn
  153.  
  154. WBInput2:    move.l    d1,a0
  155.         lea.l    FRFile(pc),a1
  156. WBInput2.1:    move.b    (a0)+,(a1)+
  157.         cmp.b    #$00,(a0)
  158.         bne    WBInput2.1
  159.         clr.b    (a1)
  160.         jmp    WBInput1.1
  161.  
  162. WBInputOut:    move.l    FRDir(pc),a0
  163.         lea.l    FRPathName(pc),a1
  164.         cmp.b    #$00,(a0)
  165.         beq    WBInputOut1.1
  166. WBInputOut1:    move.b    (a0)+,(a1)+
  167.         cmp.b    #$00,(a0)
  168.         bne    WBInputOut1
  169. WBInputOut1.1:    lea.l    FRFile(pc),a0
  170. WBInputOut2:    move.b    (a0)+,(a1)+
  171.         cmp.b    #$00,(a0)
  172.         bne    WBInputOut2
  173.         clr.b    (a1)
  174.  
  175. StartMain:    move.w    #0,Mode
  176.         moveq.l    #2,d0
  177.         openlib    Req,NoReq
  178.         openlib    Intuition,NoInt
  179.         openlib    Gfx,NoGfx
  180.  
  181.         move.l    #$31363737,AmountBuf
  182.         move.l    #$37323135,AmountBuf+4
  183.         move.l    #16777215,AmountInt
  184.  
  185. ;test for 2.0
  186.  
  187.         move.l    _IntuitionBase(pc),a0
  188.         move.w    $14(a0),d0
  189.         cmp.w    #36,d0
  190.         bcs    StartWin1
  191.  
  192. ;under 2.0
  193.         move.l    #$00,a0
  194.         lib    Intuition,LockPubScreen
  195.         move.l    d0,PubScreen
  196.         beq    NoPub
  197.  
  198. ;Get DragBar size
  199.  
  200.         move.w    #40,Win1YSize
  201.         move.l    d0,a0
  202.         move.b    $1e(a0),d0
  203.         move.w    #$00,Win1ZoomY
  204.         move.b    d0,Win1ZoomY+1
  205.         add.b    d0,Gad1YPos+1
  206.  
  207. ;use new OpenWindow (OpenWindowTagList)
  208.  
  209.         lea.l    NewWindow1(pc),a0
  210.         lea.l    Win1TagList(pc),a1
  211.         lib    Intuition,OpenWindowTagList
  212.         move.l    d0,Window1
  213.         beq    NoWin1
  214.         move.l    #$00,a0
  215.         move.l    PubScreen(pc),a1
  216.         lib    Intuition,UnlockPubScreen
  217.         move.l    #$00,PubScreen
  218.         jmp    GetRP1
  219.  
  220. ;under 1.3
  221.  
  222. StartWin1:    add.w    #10,Gad1YPos
  223.         lea.l    NewWindow1(pc),a0
  224.         lib    Intuition,OpenWindow
  225.         move.l    d0,Window1
  226.         beq    NoWin1
  227. GetRP1:        move.l    d0,a0
  228.         move.l    $32(a0),RP1
  229.         move.w    #$01,Gad1On
  230.  
  231. ;Add Menus to Window1
  232.  
  233.         move.l    Window1(pc),a0
  234.         lea.l    Menu1(pc),a1
  235.         lib    Intuition,SetMenuStrip
  236.  
  237. ;Add gadget
  238.  
  239.         lea.l    AmountGad1(pc),a1
  240.         move.l    Window1(pc),a0
  241.         move.l    #$00,d0
  242.         lib    Intuition,AddGadget
  243.  
  244. ;Refresh gad list
  245.  
  246.         lea.l    AmountGad1(pc),a0
  247.         move.l    Window1(pc),a1
  248.         move.l    #$00,a2
  249.         lib    Intuition,RefreshGadgets
  250.  
  251. ;Activate string gad
  252.  
  253.         lea.l    AmountGad1(pc),a0
  254.         move.l    Window1(pc),a1
  255.         move.l    #$00,a2
  256.         lib    Intuition,ActivateGadget
  257.  
  258. Window1IDCMP:    move.l    Window1(pc),a0
  259.         jsr    CheckIDCMP
  260.         cmp.l    #CLOSEWINDOW,d2
  261.         beq    ShutDown
  262.         cmp.l    #VANILLAKEY,d2
  263.         beq    VanillaKeys
  264.         cmp.l    #RAWKEY,d2
  265.         beq    RawKeys
  266.         cmp.l    #MENUPICK,d2
  267.         beq    Win1Menus
  268.         cmp.l    #MOUSEBUTTONS,d2
  269.         beq    ActivateGad1
  270.         jmp    Window1IDCMP
  271.  
  272. VanillaKeys:    cmp.w    #$1b,d3
  273.         beq    ShutDown
  274.         jmp    Window1IDCMP
  275. RawKeys:    cmp.w    #$5f,d3
  276.         beq    Help
  277.         jmp    Window1IDCMP
  278.  
  279. ActivateGad1:    cmp.l    #IECODE_LBUTTON,d3
  280.         bne    ActivateGadOut
  281.         lea.l    AmountGad1(pc),a0
  282.         move.l    Window1(pc),a1
  283.         move.l    #$00,a2
  284.         lib    Intuition,ActivateGadget
  285. ActivateGadOut:    jmp    Window1IDCMP
  286.  
  287. Win1Menus:    jsr    MenuNull
  288.         cmp.l    #$00,d5
  289.         beq    GetN
  290.         cmp.l    #$01,d5
  291.         beq    Help
  292.         cmp.l    #$02,d5
  293.         beq    About
  294.         cmp.l    #$03,d5
  295.         beq    ShutDown
  296.         jmp    Window1IDCMP
  297.  
  298. GetN:
  299.         cmp.l    #16777216,AmountInt
  300.         bcs    GetN0.1
  301.         move.l    Window1(pc),a0
  302.         move.l    $2e(a0),a0
  303.         lib    Intuition,DisplayBeep
  304.         move.l    Window1(pc),a0
  305.         lea.l    AmountGad1(pc),a1
  306.         lib    Intuition,RemoveGadget
  307.         move.l    #$31363737,AmountBuf
  308.         move.l    #$37323135,AmountBuf+4
  309.         move.l    #16777215,AmountInt
  310.         move.l    Window1(pc),a0
  311.         lea.l    AmountGad1(pc),a1
  312.         move.l    #$00,d0
  313.         lib    Intuition,AddGadget
  314.         lea.l    AmountGad1(pc),a0
  315.         move.l    Window1(pc),a1
  316.         move.l    #$00,a2
  317.         lib    Intuition,RefreshGadgets
  318. CheckAmountOut:    jmp    Window1IDCMP
  319.  
  320. GetN0.1:    jsr    MenusOff
  321.         lea.l    GetNName(pc),a5
  322.         move.l    #FRQABSOLUTEXYM+FRQLOADINGM,d5
  323.         jsr    FileRequester
  324.         tst.l    d0
  325.         beq    GetNOut
  326.  
  327.         lea.l    FRPathName(pc),a1
  328.         move.l    a1,d1
  329.         cmp.b    #$00,(a1)
  330.         beq    GetNOut
  331.         move.l    #MODE_OLDFILE,d2
  332.         lib    Dos,Open
  333.         move.l    d0,SCCFile
  334.         bne    GetN1
  335.         jsr    FileError
  336.         jmp    GetNOut
  337.  
  338. GetN1:        jsr    MenusOff
  339.         move.l    Window1(pc),a0
  340.         lea.l    Cheat?Txt(pc),a1
  341.         lea.l    OKTxt(pc),a2
  342.         lea.l    CancelTxt(pc),a3
  343.         move.l    #$00,d0
  344.         move.l    #$00,d1
  345.         move.l    #$100,d2
  346.         move.l    #$40,d3
  347.         lib    Intuition,AutoRequest
  348.         cmp.l    #00,d0
  349.         beq    GetN1.1
  350.         jsr    TestForCity
  351. GetN1.1:    jsr    MenusOn
  352.     
  353. GetN2:        move.l    SCCFile(pc),d1
  354.         lib    Dos,Close
  355.         move.l    #$00,SCCFile
  356.  
  357. GetNOut:    jsr    MenusOn
  358.         jmp    Window1IDCMP
  359.  
  360. FileRequester:    move.l    a5,FRTitle
  361.         move.l    d5,FRFlags
  362.         lea.l    FileRequest1(pc),a0
  363.         lib    Req,FileRequester
  364. FROut:        rts
  365.  
  366. About:        jsr    MenusOff
  367.         move.l    Window1(pc),a0
  368.         lea.l    AboutTxt1(pc),a1
  369.         move.l    #$00,a2        ;positive text
  370.         lea.l    OKTxt(pc),a3    ;a bit the wrong way around but...
  371.         move.l    #$00,d0
  372.         move.l    #$00,d1
  373.         move.l    #$134,d2
  374.         move.l    #$50,d3
  375.         lib    Intuition,AutoRequest
  376.         jsr    MenusOn
  377.         jmp    Window1IDCMP
  378.  
  379. Help:        jsr    MenusOff
  380.         move.l    Window1(pc),a0
  381.         lea.l    HelpTxt1(pc),a1
  382.         move.l    #$00,a2        ;positive text
  383.         lea.l    OKTxt(pc),a3    ;a bit the wrong way around but...
  384.         move.l    #$00,d0
  385.         move.l    #$00,d1
  386.         move.l    #$190,d2
  387.         move.l    #$40,d3
  388.         lib    Intuition,AutoRequest
  389.         jsr    MenusOn
  390.         jmp    Window1IDCMP
  391.  
  392. Finished:    move.l    Window1(pc),a0
  393.         lea.l    FinitoTxt1(pc),a1
  394.         move.l    #$00,a2        ;positive text
  395.         lea.l    OKTxt(pc),a3    ;a bit the wrong way around but...
  396.         move.l    #$00,d0
  397.         move.l    #$00,d1
  398.         move.l    #$190,d2
  399.         move.l    #$40,d3
  400.         lib    Intuition,AutoRequest
  401.         rts
  402.  
  403. TestForCity:    move.l    SCCFile(pc),d1
  404.         move.l    #65,d2
  405.         move.l    #-1,d3
  406.         lib    Dos,Seek
  407.         move.l    SCCFile(pc),d1
  408.         lea.l    FileBuf(pc),a0
  409.         move.l    a0,d2
  410.         move.l    #$04,d3
  411.         lib    Dos,Read
  412.         tst.l    d0
  413.         bne    TestForCity1    
  414.         jsr    FileError
  415.         jmp    Seek_Out
  416. TestForCity1:    move.l    FileBuf(pc),d0
  417.         cmp.l    #$43495459,d0
  418.         bne    TestForCity2
  419.         jsr    CheatCity
  420.         jmp    Seek_Out
  421. TestForCity2:    cmp.w    #1,Mode
  422.         beq    TestForCity3
  423.         move.l    Window1(pc),a0
  424.         lea.l    WrongTxt1(pc),a1
  425.         lea.l    OKTxt(pc),a2
  426.         lea.l    CancelTxt(pc),a3
  427.         move.l    #$00,d0
  428.         move.l    #$00,d1
  429.         move.l    #$100,d2
  430.         move.l    #$40,d3
  431.         lib    Intuition,AutoRequest
  432.         cmp.l    #00,d0
  433.         beq    Seek_Out
  434.         jsr    CheatCity
  435.         jmp    Seek_Out
  436. TestForCity3:    print    <"***Break",13,10,"This is not a SimCity city-file, exiting!",13,10>,_stdout
  437. Seek_Out:    rts    
  438.  
  439. CheatCity:    move.l    SCCFile(pc),d1
  440.         move.l    #3108,d2
  441.         move.l    #-1,d3
  442.         lib    Dos,Seek
  443.         move.l    SCCFile(pc),d1
  444.         lea.l    AmountInt(pc),a0
  445.         move.l    a0,d2
  446.         move.l    #$04,d3
  447.         lib    Dos,Write
  448.         cmp.w    #1,Mode
  449.         bne    CheatCity1
  450.         print    <"Your city now has $16, 777 215.",13,10>,_stdout
  451.         rts
  452. CheatCity1:    jsr    Finished
  453.         rts
  454.  
  455. DOSCheat:    move.l    #16777215,AmountInt
  456.         jsr    TestForCity
  457.         jmp    ShutDown
  458.  
  459. NoReq:        print    <"You need req.library ver.2.5 or higher!",13,10>,_stdout
  460.         jmp    ShutDown
  461. NoInt:        print    <"Can't open intuition.library!",13,10>,_stdout
  462.         jmp    ShutDown
  463. NoGfx:        print    <"Can't open graphics.library!",13,10>,_stdout
  464.         jmp    ShutDown
  465. NoWin1:        print    <"Can't open Window!",13,10>,_stdout
  466.         jmp    ShutDown
  467. NoPub:        print    <"Can't lock PubScreen!",13,10>,_stdout
  468.         jmp    ShutDown
  469.  
  470. ShutDown:    tst.l    PubScreen
  471.         beq    ShutDown9000
  472.         move.l    #$00,a0
  473.         move.l    PubScreen(pc),a1
  474.         lib    Intuition,UnlockPubScreen
  475.         move.l    #$00,PubScreen
  476.  
  477. ShutDown9000:    tst.l    SCCFile
  478.         beq    ShutDown8000
  479.         move.l    SCCFile(pc),d1
  480.         lib    Dos,Close
  481.         move.l    #$00,SCCFile
  482. ShutDown8000:    tst.l    NILFile
  483.         beq    ShutDown5000
  484.         move.l    NILFile(pc),d1
  485.         lib    Dos,Close
  486.         move.l    #$00,NILFile
  487.  
  488. ShutDown5000:    tst.l    Window1
  489.         beq    ShutDown4000
  490.         move.l    Window1(pc),a0
  491.         lib    Intuition,ClearMenuStrip
  492.         move.l    Window1(pc),a0
  493.         jsr    ClearMSGs
  494.         move.l    #$00,Window1
  495.         
  496. ShutDown4000:
  497. ShutDown3000:    tst.l    _ReqBase
  498.         beq    ShutDown2000
  499.         lea.l    FileRequest1(pc),a0
  500.         lib    Req,PurgeFiles
  501.  
  502. ;Check if launched from WB
  503.  
  504. ShutDown1999:    move.l    SCCTask,a4
  505.         move.l    pr_CLI(a4),d0
  506.         beq    ShutDownWB
  507.  
  508. ShutDown2000:    closlib    Dos
  509.         closlib    Req
  510.         closlib    Intuition
  511.         closlib    Gfx
  512.  
  513. ShutDownOut:    move.l    #RETURN_OK,d0
  514.         rts
  515.  
  516. ShutDownWB:    move.l    SCCTask(pc),a4
  517.         lib    Exec,Forbid
  518.         move.l    WBMsg(pc),a1
  519.         lib    Exec,ReplyMsg
  520.         move.l    OldLock(pc),d1
  521.         lib    Dos,CurrentDir
  522.         jmp    ShutDown2000
  523.  
  524.         INCLUDE    "FH1:Language/WF/SimCC/DosError.i"
  525.         INCLUDE    "FH1:Language/WF/SimCC/SCCCommandLineHelp.i"
  526.     
  527. MenusOn:    lea.l    Menu1(pc),a1
  528.         move.l    Window1(pc),a0
  529.         lib    Intuition,SetMenuStrip
  530.         rts
  531.  
  532. MenusOff:    move.l    Window1(pc),a0
  533.         lib    Intuition,ClearMenuStrip
  534.         rts
  535.  
  536. MenuNull:    move.l    d3,d6    
  537.                 
  538.         ror.l    #5,d6    
  539.         lsr.l    #8,d6    
  540.         lsr.l    #8,d6
  541.         lsr.l    #8,d6
  542.         lsr.l    #3,d6
  543.  
  544.         move.l    d3,d5
  545.  
  546.         ror.l    #5,d5    
  547.         ror.l    #6,d5    
  548.         lsr.l    #8,d5
  549.         lsr.l    #8,d5
  550.         lsr.l    #8,d5
  551.         lsr.l    #2,d5
  552.                 
  553.         move.l    #$00,d4
  554.         move.w    d3,d4
  555.         lsr.l    #5,d4
  556.         lsr.l    #6,d4
  557.         rts
  558.  
  559. CheckIDCMP:    move.l    $4,a6            ;made this a SubRoutine...
  560.         move.l    $56(a0),a2        ;Give it the window structure in a0
  561.         move.l    #0,d1
  562.         move.b    $0f(a2),d1
  563.         move.l    #0,d0
  564.         bset.l    d1,d0
  565.         jsr    _LVOWait(a6)    
  566.     
  567. GetMsg1:    move.l    a2,a0    
  568.         jsr    _LVOGetMsg(a6)
  569.         tst.l    d0
  570.         beq    GetMsg2
  571.     
  572.         move.l    d0,a1 
  573.         move.l    $14(a1),d2        ;answers with Class in d2,
  574.         move.w    $18(a1),d3        ;Code in d3 and
  575.         move.w    $1a(a1),a4        ;Qualifier in a4
  576.         move.l    $1c(a1),a5        ;IAddress in a5
  577.         jsr    _LVOReplyMsg(a6)
  578.         jmp    GetMsg1
  579. GetMsg2:    move.l    #-1,d0
  580.         rts
  581.  
  582. ClearMSGs:    move.l    a0,d0
  583.         tst.l    d0
  584.         beq    ClearMsg3
  585.         move.l    a0,a3
  586.         lib    Exec,Forbid
  587.         move.l    $56(a3),a2        ;Give it the window structure in a0
  588. ClearMsg1:    move.l    a2,a0    
  589.         lib    Exec,GetMsg
  590.         tst.l    d0
  591.         beq    ClearMsg2
  592.         move.l    d0,a1 
  593.         lib    Exec,ReplyMsg
  594.         jmp    ClearMsg1
  595. ClearMsg2:    move.l    a3,a0
  596.         lib    Intuition,CloseWindow
  597.         lib    Exec,Permit
  598. ClearMsg3:    rts
  599.  
  600.         ds.l    0
  601.  
  602. ;--------------------Structures------------------
  603.  
  604. ;Display stuff
  605.  
  606. Window1        dc.l    0
  607. RP1        dc.l    0
  608. PubScreen    dc.l    0
  609.  
  610. ;Library stuff (well what's needed anymore)
  611.  
  612.         libnames
  613.  
  614. ;Task stuff
  615.  
  616. SCCTask        dc.l    0
  617.  
  618. ;WB Stuff
  619.  
  620. WBMsg        dc.l    0
  621. ArgList        dc.l    0
  622. ArgsLeft    dc.l    0
  623. OldLock        dc.l    0
  624.  
  625. ;File stuff
  626.  
  627. _stdout        dc.l    0
  628. SCCAddress    dc.l    0
  629. SCCLength    dc.l    0
  630. SCCFile        dc.l    0
  631. FileBuf        dc.l    $ffffffff
  632. NILName:    dc.b    "NIL:",0
  633.         ds.l    0
  634. NILFile:    dc.l    0
  635.  
  636. ;req.lib stuff/requester stuff
  637.  
  638.         INCLUDE    "FH1:Language/WF/SimCC/SCCFileRequester.i"
  639.  
  640. ;Other stuff XIV
  641.  
  642. Mode        dc.w    0        ;0=Intuition, 1=dos
  643. Gad1On        dc.w    1        ;0=Off, 1=On
  644.  
  645. ;Texts, Part I
  646.  
  647. SCCName        dc.b    "SimCity 1.1 cheat by Tomi Blinnikka",0
  648.         ds.l    0
  649. GetNName    dc.b    "Get city file name...",0
  650.         ds.l    0
  651. PositiveText1    dc.b    "Yes",0
  652.         ds.l    0
  653. NegativeText1    dc.b    "No",0
  654.         ds.l    0
  655.  
  656. ;File stuff II
  657.  
  658. FInfo        dcb.b    260,0
  659.         ds.l    0
  660. ;Font thing
  661.  
  662. Topaz        dc.l    FontName
  663.         dc.w    8
  664.         dc.b    0
  665.         dc.b    0
  666. FontName    dc.b    "topaz.font",0
  667.         ds.l    0
  668.  
  669. ;New screen & new window structures
  670.  
  671. NewWindow1
  672.         dc.w    200,31            ;X,Y POS
  673.         dc.w    300            ;WIDTH
  674. Win1YSize    dc.w    43            ;HEIGHT
  675.         dc.b    0,1            ;PENS
  676.         dc.l    MOUSEBUTTONS+CLOSEWINDOW+GADGETDOWN+GADGETUP+VANILLAKEY+RAWKEY+MENUPICK    ;IDCMP FLAGS
  677.         dc.l    WINDOWDRAG+WINDOWDEPTH+WINDOWCLOSE+ACTIVATE    ;FLAGS
  678.         dc.l    0,0            ;GADGETS, CHECKMARK
  679.         dc.l    WindowTitle1        ;TITLE
  680.         dc.l    0            ;SCREEN ADDRESS
  681.         dc.l    0            ;BITMAP            
  682. Win1MinX    dc.w    192
  683. Win1MinY    dc.w    11,300,43        ;MINIMUM SIZE
  684.         dc.w    WBENCHSCREEN        ;TYPE
  685.         dc.l    Win1TagList
  686.  
  687. Win1TagList    dc.l    WA_AutoAdjust,0
  688.         dc.l    WA_InnerWidth,300
  689.         dc.l    WA_InnerHeight,30
  690.         dc.l    WA_Zoom,Win1ZoomXY
  691.         dc.l    TAG_DONE,0
  692.  
  693. Win1ZoomXY    dc.w    0,20,192
  694. Win1ZoomY    dc.w    11
  695.  
  696. WindowTitle1    dc.b    "SimCity cheat program",0
  697.         ds.l    0
  698.  
  699. ;Gadget structures
  700.  
  701.         INCLUDE "FH1:Language/WF/SimCC/SCCGads.i"
  702.         
  703. ;Now for all the imagery and borders etc.
  704.  
  705. GadgetBorder1    dc.w    -1        ;Initial offsets from the origin
  706.         dc.w    -2        ;LeftEdge and TopEdge
  707.         dc.b    1,2        ;Pens
  708.         dc.b    1        ;Draw Mode
  709.         dc.b    5        ;Line Count (XY)
  710.         dc.l    BorderXY1    ;XY's
  711.         dc.l    0        ;Next Border
  712.         dc.b    0
  713.         ds.l    0
  714. BorderXY1    dc.w    0,0
  715.         dc.w    90,0        
  716.         dc.w    90,11
  717.         dc.w    0,11
  718.         dc.w    0,0
  719.         dc.b    0
  720.         ds.l    0
  721.  
  722. ;Menus
  723.  
  724. Menu1:        dc.l    0            ;NEXT MENU
  725.         dc.w    0,1            ;LEFT+TOP EDGE
  726.         dc.w    110,8            ;WIDTH+HEIGHT
  727.         dc.w    $0001            ;FLAGS
  728.         dc.l    Menu1Name        ;NAME
  729.         dc.l    Menu1Item2        ;ITEMS
  730.         dc.w    0,0            ;Some Jazz-music here...        
  731.         dc.w    0,0,0            ;(with a good beat)
  732.  
  733. Menu1Name:    dc.b    "Project",0
  734.         ds.l    0
  735.  
  736. Menu1Item2:    dc.l    Menu1Item3        ;NEXT ITEM
  737.         dc.w    1,1            ;LEFT+TOP EDGE
  738.         dc.w    110,8            ;WIDTH+HEIGHT
  739.         dc.w    $0056            ;FLAGS
  740.         dc.l    0            ;MUTUAL EXCLUDE
  741.         dc.l    Menu1I2            ;ITEMFILL (IMAGE,ITEXT,GFX)
  742.         dc.l    0            ;SELECTFILL
  743.         dc.b    "C",0            ;COMMAND
  744.         dc.l    0            ;SubItem
  745.         dc.w    $ffff            ;NextSelect
  746.         
  747. Menu1I2:    dc.b    0,1            ;PENS
  748.         dc.w    0            ;MODE
  749.         dc.w    1,0            ;LEFT+TOPEDGE
  750.         dc.l    Topaz            ;FONT
  751.         dc.l    Menu1I2Text        ;TEXT
  752.         dc.l    0            ;NEXTTEXT
  753.  
  754. Menu1I2Text:    dc.b    "CHEAT!...",0
  755.         ds.l    0
  756.  
  757. Menu1Item3:    dc.l    Menu1Item4        ;NEXT ITEM
  758.         dc.w    1,11            ;LEFT+TOP EDGE
  759.         dc.w    110,8            ;WIDTH+HEIGHT
  760.         dc.w    $0056            ;FLAGS
  761.         dc.l    0            ;MUTUAL EXCLUDE
  762.         dc.l    Menu1I3            ;ITEMFILL (IMAGE,ITEXT,GFX)
  763.         dc.l    0            ;SELECTFILL
  764.         dc.b    "H",0            ;COMMAND
  765.         dc.l    0            ;SubItem
  766.         dc.w    $ffff            ;NextSelect
  767.         
  768. Menu1I3:    dc.b    0,1            ;PENS
  769.         dc.w    0            ;MODE
  770.         dc.w    1,0            ;LEFT+TOPEDGE
  771.         dc.l    Topaz            ;FONT
  772.         dc.l    Menu1I3Text        ;TEXT
  773.         dc.l    0            ;NEXTTEXT
  774.  
  775. Menu1I3Text:    dc.b    "Help...",0
  776.         ds.l    0
  777.  
  778. Menu1Item4:    dc.l    Menu1Item5        ;NEXT ITEM
  779.         dc.w    1,21            ;LEFT+TOP EDGE
  780.         dc.w    110,8            ;WIDTH+HEIGHT
  781.         dc.w    $0056            ;FLAGS
  782.         dc.l    0            ;MUTUAL EXCLUDE
  783.         dc.l    Menu1I4            ;ITEMFILL (IMAGE,ITEXT,GFX)
  784.         dc.l    0            ;SELECTFILL
  785.         dc.b    "A",0            ;COMMAND
  786.         dc.l    0            ;SubItem
  787.         dc.w    $ffff            ;NextSelect
  788.         
  789. Menu1I4:    dc.b    0,1            ;PENS
  790.         dc.w    0            ;MODE
  791.         dc.w    1,0            ;LEFT+TOPEDGE
  792.         dc.l    Topaz            ;FONT
  793.         dc.l    Menu1I4Text        ;TEXT
  794.         dc.l    0            ;NEXTTEXT
  795.  
  796. Menu1I4Text:    dc.b    "About...",0
  797.         ds.l    0
  798.  
  799. Menu1Item5:    dc.l    0            ;NEXT ITEM
  800.         dc.w    1,31            ;LEFT+TOP EDGE
  801.         dc.w    110,9            ;WIDTH+HEIGHT
  802.         dc.w    $0056            ;FLAGS
  803.         dc.l    0            ;MUTUAL EXCLUDE
  804.         dc.l    Menu1I5            ;ITEMFILL (IMAGE, ITEXT,GFX)
  805.         dc.l    0            ;SELECTFILL
  806.         dc.b     "Q",0            ;COMMAND
  807.         dc.l    0            ;IF<>0SubItem Shows ->
  808.         dc.w    $ffff            ;NextSelect
  809.  
  810. Menu1I5:    dc.b    0,1            ;PENS
  811.         dc.w    0            ;MODE
  812.         dc.w    1,0            ;LEFT+TOPEDGE
  813.         dc.l    Topaz            ;FONT
  814.         dc.l    Menu1I5Text        ;TEXT
  815.         dc.l    0            ;NEXTTEXT
  816.     
  817. Menu1I5Text:    dc.b    "Quit",0
  818.         ds.l    0
  819.  
  820. ;Texts, Part II
  821.  
  822. AboutTxt1:    dc.b    3,1            ;PENS
  823.         dc.w    0            ;MODE
  824.         dc.w    10,10            ;LEFT+TOPEDGE
  825.         dc.l    Topaz            ;FONT
  826.         dc.l    AboutText1        ;TEXT
  827.         dc.l    AboutTxt2        ;NEXTTEXT
  828.         ds.l    0
  829.         
  830. AboutTxt2:    dc.b    3,1            ;PENS
  831.         dc.w    4            ;MODE
  832.         dc.w    10,20            ;LEFT+TOPEDGE
  833.         dc.l    Topaz            ;FONT
  834.         dc.l    AboutText2        ;TEXT
  835.         dc.l    AboutTxt3        ;NEXTTEXT
  836.         ds.l    0
  837.  
  838. AboutTxt3:    dc.b    3,1            ;PENS
  839.         dc.w    4            ;MODE
  840.         dc.w    10,30            ;LEFT+TOPEDGE
  841.         dc.l    Topaz            ;FONT
  842.         dc.l    AboutText3        ;TEXT
  843.         dc.l    AboutTxt4        ;NEXTTEXT
  844.         ds.l    0
  845.  
  846. AboutTxt4:    dc.b    3,1            ;PENS
  847.         dc.w    4            ;MODE
  848.         dc.w    10,50            ;LEFT+TOPEDGE
  849.         dc.l    Topaz            ;FONT
  850.         dc.l    AboutText4        ;TEXT
  851.         dc.l    0            ;NEXTTEXT
  852.         ds.l    0
  853.  
  854. AboutText1:    dc.b    "SimCity 1.1 cheat program v.1.02",0
  855.         ds.l    0                          
  856. AboutText2:    dc.b    "               by",0
  857.         ds.l    0
  858. AboutText3:    dc.b    "         Tomi Blinnikka",0
  859.         ds.l    0
  860. AboutText4:    dc.b    "        (C)opyright 1991",0
  861.         ds.l    0
  862.  
  863. HelpTxt1:    dc.b    3,1            ;PENS
  864.         dc.w    4            ;MODE
  865.         dc.w    10,10            ;LEFT+TOPEDGE
  866.         dc.l    Topaz            ;FONT
  867.         dc.l    HelpText1        ;TEXT
  868.         dc.l    HelpTxt2        ;NEXTTEXT
  869.         ds.l    0
  870.  
  871. HelpTxt2:    dc.b    3,1            ;PENS
  872.         dc.w    4            ;MODE
  873.         dc.w    10,19            ;LEFT+TOPEDGE
  874.         dc.l    Topaz            ;FONT
  875.         dc.l    HelpText2        ;TEXT
  876.         dc.l    HelpTxt3        ;NEXTTEXT
  877.         ds.l    0
  878.  
  879. HelpTxt3:    dc.b    3,1            ;PENS
  880.         dc.w    4            ;MODE
  881.         dc.w    10,28            ;LEFT+TOPEDGE
  882.         dc.l    Topaz            ;FONT
  883.         dc.l    HelpText3        ;TEXT
  884.         dc.l    0            ;NEXTTEXT
  885.         ds.l    0
  886.  
  887. HelpText1:    dc.b    "1. Select amount of money ($0 - $16,777 215).",0
  888.         ds.l    0
  889. HelpText2:    dc.b    "2. Choose CHEAT!.",0
  890.         ds.l    0
  891. HelpText3:    dc.b    "3. Give SimCity CITY-file's filename.",0
  892.         ds.l    0
  893.  
  894. FinitoTxt1:    dc.b    3,1            ;PENS
  895.         dc.w    4            ;MODE
  896.         dc.w    10,20            ;LEFT+TOPEDGE
  897.         dc.l    Topaz            ;FONT
  898.         dc.l    FinitoText1        ;TEXT
  899.         dc.l    0            ;NEXTTEXT
  900.         ds.l    0
  901. FinitoText1:    dc.b    "Wow! I just donated your city a lot of money!",0
  902.         ds.l    0
  903.  
  904. OKTxt:        dc.b    3,1            ;PENS
  905.         dc.w    0            ;MODE
  906.         dc.w    6,3            ;LEFT+TOPEDGE
  907.         dc.l    Topaz            ;FONT
  908.         dc.l    OKText1            ;TEXT
  909.         dc.l    0            ;NEXTTEXT
  910.         ds.l    0
  911. OKText1:    dc.b    "OK",0
  912.         ds.l    0
  913. CancelTxt:    dc.b    3,1            ;PENS
  914.         dc.w    0            ;MODE
  915.         dc.w    6,3            ;LEFT+TOPEDGE
  916.         dc.l    Topaz            ;FONT
  917.         dc.l    CancelText1        ;TEXT
  918.         dc.l    0            ;NEXTTEXT
  919.         ds.l    0
  920. CancelText1:    dc.b    "CANCEL!",0
  921.         ds.l    0
  922.  
  923. Cheat?Txt:    dc.b    3,1            ;PENS
  924.         dc.w    4            ;MODE
  925.         dc.w    10,10            ;LEFT+TOPEDGE
  926.         dc.l    Topaz            ;FONT
  927.         dc.l    CheatText1        ;TEXT
  928.         dc.l    0            ;NEXTTEXT
  929.         ds.l    0
  930.  
  931. CheatText1:    dc.b    "Cheat on this city?",0
  932.         ds.l    0                          
  933.  
  934. WrongTxt1:    dc.b    3,1            ;PENS
  935.         dc.w    4            ;MODE
  936.         dc.w    10,10            ;LEFT+TOPEDGE
  937.         dc.l    Topaz            ;FONT
  938.         dc.l    FWrongText1        ;TEXT
  939.         dc.l    0            ;NEXTTEXT
  940.         ds.l    0
  941.  
  942. FWrongText1:    dc.b    "Incorrect file! Try anyway?",0
  943.         ds.l    0
  944.  
  945. Win1Txt1:    dc.b    1,2            ;PENS
  946.         dc.w    0            ;MODE
  947.         dc.w    -103,-18        ;LEFT+TOPEDGE
  948.         dc.l    Topaz            ;FONT
  949.         dc.l    Win1Text1        ;TEXT
  950.         dc.l    0            ;NEXTTEXT
  951.         ds.l    0
  952. Win1Text1:    dc.b    "Amount of money? ($0 - $16, 777 215)",0
  953.         ds.l    0
  954.  
  955.         END
  956.